require 'net'

module NET

  def open_url(url)

    if url=='http://wrong/'
      raise SocketError, 'getaddrinfo: Temporary failure in name resolution', caller
    end
    test_rss = Dir.glob((File.dirname(__FILE__)+"/../../fixtures/*.xml"))
    yield(IO.read(test_rss[rand(test_rss.size)]))

  end

end



